<?php
/**
 * Joomla! 1.5 component NS Pro
 *
 * @version $Id: view.html.php 2009-04-28 01:47:12 svn $
 * @author Christopher Mavros
 * @package Joomla
 * @subpackage NS Pro
 * @license GNU/GPL
 *
 */

// no direct access
defined('_JEXEC') or die('Restricted access');

// Import Joomla! libraries
jimport( 'joomla.application.component.view');
class NsproViewListEdit extends JView {

    function display($tpl = null)
    {

        $model  =& $this->getModel();
        $mlst   = $model->getList();
        $isNew  = ($mlst->id < 1);

        $text = $isNew ? JText::_( 'New' ) : JText::_( 'Edit' );
				$jversion = new JVersion();
				if ($jversion->RELEASE == '1.5') {
					JToolBarHelper::title(JText::_( 'Lists' ).': <small><small>[ ' . $text.' ]</small></small>', 'massemail.png');
				}
				else {
					JToolBarHelper::title(   JText::_( 'Lists' ).': <small><small>[ ' . $text.' ]</small></small>', 'groups-add.png' );
				}        
        JToolBarHelper::save('lsave');
        if ($isNew)  {
            JToolBarHelper::cancel('lcancel');
        } else {
            JToolBarHelper::cancel( 'lcancel');
        }

        $this->assignRef('mlst', $mlst);

        parent::display($tpl);
    }
}
?>